<% unless controller.controller_name == "sessions" and controller.action_name == "new" %>
  <ul class="toolbar">

    <% if current_user.nil? %>

      <li class="last"><%= link_to _("login"), new_session_path %></li>

    <% else %>
      <li>
        <%= link_to "#{image_tag current_user.avatar.url(:thumb), :class => 'avatar', :alt => ""}", current_user %>
        <%= link_to current_user.name, current_user %>
      </li>

      <li><%= link_to _("edit profile"), edit_user_path(current_user) %></li>

      <li><%= link_to _("invite friends"), new_invitation_path %></li>

      <li class="last"><%= link_to _("logout"), session_path, :method => :delete %></li>

    <% end %>
  </ul>
<% end %>

  <%= render :partial => "common/search" %>

<div style="text-align:left">
  <span class="tagline">comparte tus recetas</span>
  <p class="logo">
    <%= link_to "<strong>rezets</strong>.com <span class=\"version\">v0.1</span>", :controller => "home", :action => "index" %>
  </p>
  <ul class="main-links">
    <li><%= link_to _("start"), :controller => "home", :action => "index" %></li>
    <li><%= link_to _("recipes"), recipes_path %></li>
    <li class="last"><%= link_to _("categories"), categories_path %></li>
  </ul>
</div>
